package com.example.noobpackage.ui.packagemarketdetail

import androidx.lifecycle.LiveData
import androidx.lifecycle.ViewModel
import androidx.lifecycle.viewModelScope
import com.example.noobpackage.logic.model.MarketPackageData
import com.example.noobpackage.logic.network.MarketAcceptResponse
import com.example.noobpackage.logic.network.MarketPackageService
import com.example.noobpackage.logic.network.ServiceCreator
import com.example.noobpackage.logic.repository.MarketRepository
import kotlinx.coroutines.launch

class PackageMarketDetailViewModel : ViewModel() {
    private val marketPackageService = ServiceCreator.create<MarketPackageService>()
    lateinit var acceptRes: LiveData<MarketAcceptResponse>

    // 接受请求
    fun acceptMarketPackage(id: String, account: Long): LiveData<MarketAcceptResponse> {
        return MarketRepository.acceptMarketPackage(id, account)
    }


}